﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BLL.BusinessRules;

namespace BLL
{
    public class DMDONVITINH: BusinessObject
    {
        public int MaDonViTinh { get; set; }
        public string MaCode { get; set; }
        public string TenDonViTinh { get; set; }
        public bool? IsUse { get; set; }
        public int? CreateBy { get; set; }
        public int? ModifiedBy { get; set; }
        public DateTime? ModifiedOn { get; set; }

        public DMDONVITINH()
        {
            AddRule(new ValidateRequired("TenDonViTinh"));
            AddRule(new ValidateLength("TenDonViTinh",1,10));
        }

        public DMDONVITINH(int maDonViTinh, string maCode, string tenDonViTinh, bool? isUse, int? createBy, int? modifiedBy, DateTime? modifiedOn)
            :this()
        {
            MaDonViTinh = maDonViTinh;
            MaCode = maCode;
            TenDonViTinh = tenDonViTinh;
            IsUse = isUse;
            CreateBy = createBy;
            ModifiedBy = modifiedBy;
            ModifiedOn = modifiedOn;
        }

    }
}
